﻿<UserControl x:Class="DIST.LR.ZHJG.Pgybc.Zbgl_KPITYPE"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:toolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit"
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
    xmlns:qsf="clr-namespace:Telerik.Windows.Controls.QuickStart;assembly=Telerik.Windows.Controls"
    xmlns:input="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Input"

    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="800">

    <UserControl.Resources>
        <SolidColorBrush Color="#d6d4d4" x:Key="BorderBrush"/>
        <Style TargetType="TextBlock" x:Key="TitleStyle">
            <Setter Property="Foreground" Value="#25a0da" />
            <Setter Property="FontSize" Value="23" />
            <Setter Property="FontFamily" Value="/Telerik.Windows.QuickStartUITheme;component/Fonts/MyriadPro-Light.otf#Myriad Pro Light" />
            <Setter Property="Margin" Value="10 5" />
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="HorizontalAlignment" Value="Center"/>
        </Style>
        <Style TargetType="TextBlock" x:Key="TitleStyleL">
            <Setter Property="Foreground" Value="Green" />
            <Setter Property="FontSize" Value="20" />
            <Setter Property="Margin" Value="20" />
            <Setter Property="FontFamily" Value="/DIST.LR.ZHJG.Utility.Silverlight;component/Fonts/Fonts.zip#Microsoft YaHei"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="HorizontalAlignment" Value="Right"/>
        </Style>
        <Style TargetType="TextBlock" x:Key="TitleStyleR">
            <Setter Property="Foreground" Value="Green" />
            <Setter Property="FontSize" Value="20" />
            <Setter Property="Margin" Value="20" />
            <Setter Property="FontFamily" Value="/DIST.LR.ZHJG.Utility.Silverlight;component/Fonts/Fonts.zip#Microsoft YaHei"/>
            <Setter Property="VerticalAlignment" Value="Center"/>
            <Setter Property="HorizontalAlignment" Value="Left"/>
        </Style>
        <Style x:Key="RadButtonStyle" TargetType="telerik:RadButton">
            <Setter Property="BorderThickness" Value="0"/>
            <Setter Property="Foreground" Value="Green" />
            <Setter Property="FontFamily" Value="FZHei-B01S" />
            <Setter Property="FontSize" Value="16" />
            <Setter Property="Background" Value="Transparent"/>
            <Setter Property="HorizontalContentAlignment" Value="Right"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="Padding" Value="3"/>
        </Style>
    </UserControl.Resources>

    <Grid x:Name="LayoutRoot" Background="Transparent">
        <Grid Margin="10,5,5,5">
            <Grid.RowDefinitions>
                <RowDefinition Height="0.15*"></RowDefinition>
                <RowDefinition Height="0.15*"></RowDefinition>
                <RowDefinition Height="*"></RowDefinition>
            </Grid.RowDefinitions>
            <Border BorderBrush="{StaticResource BorderBrush}" BorderThickness="1 1 1 1">
                <TextBlock Text="指 标 类 型" Style="{StaticResource TitleStyle}"/>
            </Border>
            <Border Background="Transparent" BorderBrush="{StaticResource BorderBrush}" BorderThickness="1 0 1 1" Grid.Row="1">
            </Border>
            <Border Background="Transparent" BorderBrush="{StaticResource BorderBrush}" BorderThickness="1 0 1 1" Grid.Row="2">
            </Border>
            <Grid Grid.Row="1" >
                <TextBlock Text="当前位置→指标类型" VerticalAlignment="Center" HorizontalAlignment="Left"></TextBlock>
                <telerik:RadButton x:Name="update" Style="{StaticResource RadButtonStyle}" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0 0 20 0">
                    <telerik:RadButton.ContentTemplate>
                        <DataTemplate>
                            <Grid>
                                <TextBlock Text="新增指标类型"/>
                            </Grid>
                        </DataTemplate>
                    </telerik:RadButton.ContentTemplate>
                </telerik:RadButton>
                <!--<TextBlock Text="选择表：" VerticalAlignment="Center" HorizontalAlignment="Center"></TextBlock>
                <telerik:RadComboBox Width="90" Name="kpiTab">
                    <telerik:RadComboBoxItem Content="指标类型"/>
                    <telerik:RadComboBoxItem Content="指标配置"/>
                    <telerik:RadComboBoxItem Content="指标来源"/>
                    <telerik:RadComboBoxItem Content="指标值配置表"/>
                </telerik:RadComboBox>
                <TextBlock Text="选择类型：" VerticalAlignment="Center" HorizontalAlignment="Center"></TextBlock>
                <telerik:RadComboBox Width="70" Name="kpiType">
                    <telerik:RadComboBoxItem Content="资源概览"/>
                    <telerik:RadComboBoxItem Content="批"/>
                    <telerik:RadComboBoxItem Content="供"/>
                    <telerik:RadComboBoxItem Content="用"/>
                    <telerik:RadComboBoxItem Content="补"/>
                    <telerik:RadComboBoxItem Content="查"/>
                </telerik:RadComboBox>
                <TextBlock Text="指标配置：" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5,0,0,0"></TextBlock>
                <telerik:RadComboBox Width="100" Name="kpiName">
                    <telerik:RadComboBoxItem Content="市区总面积" FontSize="13"/>
                    <telerik:RadComboBoxItem Content="耕地面积"/>
                    <telerik:RadComboBoxItem Content="林地面积"/>
                    <telerik:RadComboBoxItem Content="市区（不含萧山、余杭）"/>
                    <telerik:RadComboBoxItem Content="补"/>
                    <telerik:RadComboBoxItem Content="查"/>
                </telerik:RadComboBox>
                <TextBlock Text="请选择：" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5,0,0,0"></TextBlock>
                <telerik:RadComboBox Width="50" Name="Action">
                    <telerik:RadComboBoxItem Content="新增"/>
                    <telerik:RadComboBoxItem Content="删除"/>
                    <telerik:RadComboBoxItem Content="修改"/>
                    <telerik:RadComboBoxItem Content="查询"/>
                </telerik:RadComboBox>-->
                
            </Grid>
            <Grid Grid.Row="2">
                <telerik:RadGridView x:Name="RadGridView1" ItemsSource="{Binding KpiTypeInfo}"               
                AutoGenerateColumns="False" ShowGroupPanel="False"
                CanUserFreezeColumns="False" RowIndicatorVisibility="Collapsed"
                VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
                ReorderColumnsMode="None" IsReadOnly="True" ShowInsertRow="False" 
                ShowGroupFooters="False" ShowColumnHeaders="True" ShowColumnFooters="False" 
                 SelectionUnit="FullRow" FontSize="13" telerik:Theming.Theme="Metro">
                    <telerik:RadGridView.Columns>
                        <telerik:GridViewDataColumn Header="指标编号" HeaderTextAlignment="Center" DataMemberBinding="{Binding Id}" Width="0.1*"/>
                        <telerik:GridViewDataColumn Header="指标类型名称" HeaderTextAlignment="Center" DataMemberBinding="{Binding Name, Mode=TwoWay}" Width="0.2*">
                            <telerik:GridViewDataColumn.CellTemplate>
                                <DataTemplate>
                                    <TextBlock Text="{Binding Name}" />
                                </DataTemplate>
                            </telerik:GridViewDataColumn.CellTemplate>
                            <telerik:GridViewDataColumn.CellEditTemplate>
                                <DataTemplate>
                                    <TextBox Text="{Binding Name, Mode=TwoWay}"  />
                                </DataTemplate>
                            </telerik:GridViewDataColumn.CellEditTemplate>
                        </telerik:GridViewDataColumn>
                        <telerik:GridViewDataColumn Header="操作" HeaderTextAlignment="Center" DataMemberBinding="{Binding Discontinued, Mode=TwoWay}" TextAlignment="Center" Width="0.15*">
                            <telerik:GridViewDataColumn.CellTemplate>
                                <DataTemplate>
                                    <StackPanel x:Name="sp" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
                                        <Button x:Name="notify" Content="修 改" Margin="5 5 5 5" Click="notify_Click"></Button>
                                        <Button x:Name="delete" Content="删 除" Margin="5 5 5 5" Click="delete_Click"></Button>
                                    </StackPanel>
                                </DataTemplate>
                            </telerik:GridViewDataColumn.CellTemplate>
                        </telerik:GridViewDataColumn>
                    </telerik:RadGridView.Columns>
                </telerik:RadGridView>
            </Grid>
        </Grid>
    </Grid>
</UserControl>
